using BunnyEater.Common.ResponseOutput;
using BunnyEater.Domain.Base;
using BunnyEater.Service.TraceableService.MaterialService.Dto;
using System.Threading.Tasks;

namespace BunnyEater.Service.TraceableService.MaterialService
{
    /// <summary>
    /// 物料服务接口，定义物料相关的业务操作
    /// </summary>
    public interface IMaterialService : ITransientService
    {
        /// <summary>
        /// 新增物料
        /// </summary>
        /// <param name="dto">物料信息</param>
        /// <returns>操作结果</returns>
        Task<ResponseReturnsEntity<bool>> AddMaterial(MaterialListDto dto);
        /// <summary>
        /// 更新物料信息
        /// </summary>
        /// <param name="dto">物料信息</param>
        /// <returns>操作结果</returns>
        Task<ResponseReturnsEntity<bool>> UptMaterial(MaterialListDto dto);
        /// <summary>
        /// 删除物料（逻辑删除）
        /// </summary>
        /// <param name="id">物料Id</param>
        /// <returns>操作结果</returns>
        Task<ResponseReturnsEntity<bool>> DeleteMaterial(string id);
        /// <summary>
        /// 根据Id获取物料信息
        /// </summary>
        /// <param name="id">物料Id</param>
        /// <returns>物料信息</returns>
        Task<ResponseReturnsEntity<MaterialListDto>> GetMaterialById(string id);
        /// <summary>
        /// 分页获取物料列表
        /// </summary>
        /// <param name="query">分页查询参数</param>
        /// <returns>物料分页数据</returns>
        Task<ResponseReturnsEntity<Page<MaterialListDto>>> GetPagedMaterialsAsync(MaterialPagedQueryDto query);
    }
}